package com.lagou.rabbitmq.demo.delayedpay.util;

import java.util.Random;

public class Utils {
    private static final Random RANDOM = new Random();

    public static String generateUserId() {
        int i = RANDOM.nextInt(1000000);
        String format = String.format("%06d", i);
        return "u00001-" + format;
    }

    public static String generateOrderId() {
        int i = RANDOM.nextInt(1000000);
        String format = String.format("%06d", i);
        return "oid00001-" + format;
    }

     public static String generateItemId() {
         int i = RANDOM.nextInt(1000000);
         String format = String.format("%06d", i);
         return "item00001-" + format;
     }

}
